package com.emotion.sshticket.dao;

import javax.annotation.Resource;

import org.apache.ibatis.session.SqlSession;
import org.springframework.stereotype.Repository;

import com.emotion.sshticket.vo.TicketVO;

@Repository("frontDAO")
public class FrontDAO {
	private String sqlName = "frontSQL";

	@Resource(name="sqlSession")
	private SqlSession sqlSession;

	public int getCheckDuplacateCount(String userEmail) throws Exception {
		return (Integer) sqlSession.selectOne(sqlName + ".getCheckDuplacateCount", userEmail);
	}

	public void insertTicketingInfo(TicketVO ticketVO) throws Exception {
		sqlSession.insert(sqlName + ".insertTicketingInfo", ticketVO);
	}
}